package com.sm.sales_management.service.impl;


import com.sm.sales_management.domain.Salesman;
import com.sm.sales_management.mapper.SalesmanMapper;
import com.sm.sales_management.service.ISalesmanService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SalesmanServiceImpl implements ISalesmanService {

    @Autowired
    SalesmanMapper salesmanMapper;

    @Override
    public List<Salesman> selectAllSaleman() {
        return salesmanMapper.selectAllSaleman();
    }

    @Override
    public Integer delete(int id) {
        return salesmanMapper.delete(id);
    }

    @Override
    public Integer updateSalesman(Salesman salesman) {
        return salesmanMapper.updateSalesman(salesman);
    }

    @Override
    public Integer insertSaleman(Salesman salesman) {
        return salesmanMapper.insertSaleman(salesman);
    }
}
